﻿<%@ page contentType="text/html;charset=UTF-8" language="java"%>
<%@ page import="java.util.HashSet"%>
<%@ page import="java.util.Set"%>
<%@ page import="java.util.Map"%>
<%@ page import="java.io.BufferedReader"%>
<%@ page import="java.io.IOException"%>
<%@ page import="java.io.InputStream"%>
<%@ page import="java.io.InputStreamReader"%>
<%@ page import="java.net.HttpURLConnection"%>
<%@ page import="java.net.MalformedURLException"%>
<%@ page import="java.net.URL"%>
<%
URL url = new URL("http://localhost:8080/franExample/index.jsp");
HttpURLConnection huc = (HttpURLConnection) url.openConnection();
huc.connect();
InputStream is=huc.getInputStream();
InputStreamReader isr = new InputStreamReader(is,"UTF-8");
BufferedReader br = new BufferedReader(isr);
StringBuffer sb = new StringBuffer();
for(String line; (line=br.readLine())!=null; ){
     sb.append(line);
     //out.println(line);
}
//System.out.println(sb.toString());
huc.disconnect();

String libUrl="gmcc_ext";
String smcPrefix="";
Map model=(Map)request.getAttribute("model");
request.removeAttribute("model");
if(request.getAttribute("margins")!=null) model.put("margins", request.getAttribute("margins"));
if("true".equals(request.getParameter("headeroff"))){
        model.put("margins","0 0 0 0");
}//if
if(null!=model){
if(!model.containsKey("margins")) model.put("margins","141 0 0 0");
if(!model.containsKey("smcPrefix") || ((String)model.get("smcPrefix")).length()==0) model.put("smcPrefix","http://pac-app.gmcc.net/smc");
libUrl = (String)model.get("libUrl");
smcPrefix  = (String)model.get("smcPrefix");
}
%>
		<link rel="stylesheet" type="text/css"
			href="<%= libUrl %>/ext/resources/css/ext-all.css" />
		<script type="text/javascript"
			src="<%= libUrl %>/ext/adapter/ext/ext-base.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/ext/ext-all.js"></script>
		<link rel="stylesheet" type="text/css"
			href="<%= libUrl %>/ext-portal/portal.css" />

		<script type="text/javascript"
			src="<%= libUrl %>/ext-portal/Portal.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/ext-portal/PortalColumn.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/ext-portal/Portlet.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/ext-portal/iframe.js"></script>

		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myRefactor/saveCurLayoutFn.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myRefactor/myPortalPanel.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myRefactor/handleMaximizeFn.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myRefactor/myPortletPanel.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myRefactor/handleMinimizeFn.js"></script>

		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myNewjs/MyChannalTree.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myNewjs/MyTopPanel.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myNewjs/MyTopPanel1.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myNewjs/MyCenterPanel.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myNewjs/setupDropTargetsFn.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/myNewjs/getChannelFromNodeFn.js"></script>
		<script>
        //Ext.BLANK_IMAGE_URL = "ext/resources/images/default/s.gif";
        //app vars
        var desktopName = 'temp123';
        var local_test_url = "http://localhost:8080/franExample/index.jsp";
        var myWestTree_dataUrl ='data/emulation/proxy.jsp';
	Ext.onReady(function() {
		init();
	});
    </script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/index.js"></script>
		<script type="text/javascript"
			src="<%= libUrl %>/javascripts/init_1.js"></script>
